/**
 * FileName: ManagerMessageServiceImpl
 * Author:   jiao
 * Date:     2019/5/4 15:57
 * Description: 管理员消息生成服务层
 * History:
 * <author>          <time>          <version>          <desc>
 * 作者姓名           修改时间           版本号              描述
 */
package service;

import dao.ManagerMessageMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import pojo.ManagerMessage;

import javax.xml.ws.ServiceMode;

/**
 * 〈一句话功能简述〉<br> 
 * 〈管理员消息生成服务层〉
 *
 * @author jiao
 * @create 2019/5/4
 * @since 1.0.0
 */
@Service
public class ManagerMessageServiceImpl implements ManagerMessageServiceI {

    @Autowired
    private ManagerMessageMapper managerMessageMapper;

    @Override
    public boolean CreatMessage(ManagerMessage managerMessage) {
        int i=managerMessageMapper.insert(managerMessage);
        if(i>0){
            return  true;
        }else
            return false;
    }

    @Override
    public boolean DeleteMessage(Integer essayId) {
        Integer i=managerMessageMapper.deleteByEssayId(essayId);
        if(i>0){
            return true;
        }else
            return false;
    }
}
